<template>
	<sl-page title="加入流量中心">
		<view class="marketing">
			<view class="">
				<sl-image :value="salerApplyParam.recruitImage"></sl-image>
			</view>
			<sl-flooter>
				<view class="btn-primary" @click="createApplyPage()">立即申请</view>
			</sl-flooter>
		</view>
	</sl-page>
</template>

<script>
	import DistributionApi from '@/api/distribution/distribution.js';
	import Constants from '@/constants';
	//
	export default {
		//
		name: 'marketing',
		//
		mixins: [Constants],
		//
		components: {},
		//
		data() {
			return {
				//当前系统配置分销参数，分销员响应
				salerApplyParam: {},
			};
		},
		//
		onLoad(options) {
			this.getRecruit();
		},
		//
		methods: {
			//得到分销招幕信息
			getRecruit: async function() {
				let res = await DistributionApi.recruit();
				this.salerApplyParam = res.obj;
			},
			//申请
			createApplyPage() {
				this.$app.navTo(this.pages.createApplyPage, this.salerApplyParam);
			}
		}
	};
</script>

<style lang="scss" scoped>
	.marketing {

		.marketing-image {
			position: relative;
			width: 100%;
		}
	}
</style>